using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;
using SOEI.Solution.DomainEntities.ContractManagement;

namespace SOEI.Solution.EntityFrameworkCore.EntityMapper
{
    public class ContractBodyMapper : AbpBaseMapper, IEntityTypeConfiguration<ContractBody>
    {
        public void Configure(EntityTypeBuilder<ContractBody> builder)
        {
            builder.SetAttrbuteEntity();

            builder.HasIndex(zw => zw.ContractSummaryId);
            builder.HasKey(zw => new { zw.ContractSummaryId, zw.Key });
        }
    }
}
